<%@ page contentType="text/html;charset=UTF-8" %>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<html>
<head>
	<title>版本管理</title>
	<script>
		$(document).ready(function() {
			//聚焦第一个输入框
			$("#user-tab").addClass("active");
		});
	</script>
</head>
<jsp:include page="/WEB-INF/views/common.jsp"/>
<body>
	<c:if test="${not empty message}">
		<div id="message" class="alert alert-success"><button data-dismiss="alert" class="close">×</button>${message}</div>
	</c:if>
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
        <tr>
            <th>平台</th>
            <th>版本值</th>
            <th>版本字符串</th>
            <th>更新地址</th>
            <th>是否发布</th>
            <th>版本说明</th>
        </tr>
        </thead>
		<tbody>
		<c:forEach items="${list}" var="entity">
			<tr>
				<td>${entity.versionPlatform}</td>
				<td>${entity.versionValue}</td>
                <td>${entity.versionString}</td>
                <td>${entity.url}</td>
                <td>${entity.deplyed}</td>
                <td>${entity.description}</td>
                <td>
					<shiro:hasPermission name="user:edit">
	    				<a href="/account/user/update/${user.id}" id="editLink-${user.name}">修改</a>
                        <a href="/account/user/delete/${user.id}">删除</a>
					</shiro:hasPermission>
				</td>
			</tr>
		</c:forEach>
		</tbody>
	</table>
</body>
</html>
